#ifndef _led_h_
#define _led_h_

#include "stm32f10x.h"

#define WS2812_RCC_PORT		RCC_APB2Periph_GPIOB
#define WS2812_PIN				GPIO_Pin_9
#define WS2812_PORT				GPIOB

#define		RGB_LED_HIGH	WS2812_PORT->BSRR = WS2812_PIN;
#define 	RGB_LED_LOW		WS2812_PORT->BRR = WS2812_PIN;

typedef enum{
	RED = 1,	
	GREEN,		
	BLUE,			
	YELLOW,		
	PURPLE,		
	CYAN,			
	WHITE,		
	BLACK,		
}LedColor;

void LedInit(void);
void RgbLedBlinkFast(LedColor ledColor);
void TopLedColorSet(const LedColor ledColor);
void RGB_LED_Reset(void);
void RgbLedBlinkSlow(const LedColor ledColor);
void TopLedBlink(LedColor ledColor, uint8_t frequency, uint16_t delayMs);
#endif

